package com.ujoin.action.collection;

import org.springframework.beans.factory.annotation.Autowired;

import com.ujoin.bean.Collection;
import com.ujoin.service.CollectionService;
import com.ujoin.util.ActionEnhanced;

public class FindCollectionByActivityIdAction extends ActionEnhanced {

	private int activityId;
	
	public int getActivityId() {
		return activityId;
	}

	public void setActivityId(int activityId) {
		this.activityId = activityId;
	}

	@Autowired
	private CollectionService collectionService;
	
	@Override
	public String execute() {
		setJson(collectionService.findCollectionByActivityId(activityId));
		return SUCCESS;
	}
}
